package test;

import java.util.Date;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Set;

/**
 * Created by yangliwei on 2018/3/7.
 */
public class Demo1 extends Date{
    public static void main(String[] args) {
        new Demo1().test();
    }

    protected void test(){
        int  a = 1;
        int b = 13;
        do{
            b-=a;
            a++;
        }while (--b >=0);
        System.out.println(b);
        System.out.println(super.getClass().toString());
        System.out.println(getClass().getSuperclass().getName());
        Set<String> sets = new HashSet();
        sets.add("a");
        Iterator<String> temp = sets.iterator();
        while(temp.hasNext()){
            System.out.println(temp.next());
        }
    }
    abstract class A{
        protected abstract void a();
    }
}
